{template 'common/header'}
<div id="js-module-plugin" class="module-plugin-container" ng-controller="modulePluginCtrl">
	<div class="row">
		<div class="col-sm-3">
			<div class="input-group">
				<input type="text" name="search" id="" value="" class="form-control" placeholder="输入要搜索的插件">
				<span class="input-group-btn"><button class="btn btn-default"><i class="fa fa-search"></i></button></span>
			</div>
		</div>
	</div>
	<div class="module-plugin-list">
		{php $_GPC['version_id'] = empty($_GPC['version_id']) ? 0 : intval($_GPC['version_id']);}
		{loop $plugin_list $plugin}
		<div class="item">
			<div class="item-box">
				<a class="info" href="{php echo url('module/welcome/display', array('module_name' => $plugin['plugin_info']['name'], 'version_id' => $_GPC['version_id']))}">
					{if !empty($plugin['plugin_info']['logo'])}
						<img src="{$plugin['plugin_info']['logo']}" alt="" class="logo">
					{else}
						<img src="{php echo tomedia("addons/" .$plugin['plugin_info']['name'] . "/icon.jpg")}" class="logo" onerror="this.src='./resource/images/gw-wx.gif'">
					{/if}
					<span class="name text-over">{$plugin['plugin_info']['title']}</span>
				</a>
				<div class="action">
					{if empty($plugin['module_shortcut'])}
					<a href="{php echo url('module/plugin/module_shortcut', array('plugin_name' => $plugin['plugin_info']['name'], 'module_shortcut' => 1))}" class="action-show" data-toggle="tooltip" data-placement="bottom" data-title="显示到菜单">
						<i class="wi wi-eye"></i>
					</a>
					{else}
					<a href="{php echo url('module/plugin/module_shortcut', array('plugin_name' => $plugin['plugin_info']['name'], 'module_shortcut' => 0))}" class="action-show" data-toggle="tooltip" data-placement="bottom" data-title="从菜单移除">
						<i class="wi wi-eye"></i>
					</a>
					{/if}
					<a href="{php echo url('module/welcome/display', array('module_name' => $plugin['plugin_info']['name'], 'version_id' => $_GPC['version_id']))}" class="action-in"><i class="wi wi-denglu"></i> 进入</a>
				</div>
			</div>
		</div>
		{/loop}
	</div>
</div>
<script>
	angular.module('moduleApp').value('config', {

	});
	angular.bootstrap($('#js-module-plugin'), ['moduleApp']);
</script>
{template 'common/footer'}
